package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.MgmtBaseSpuMapper;
import com.ruoyi.system.domain.MgmtBaseSpu;
import com.ruoyi.system.service.IMgmtBaseSpuService;

/**
 * 产品管理Service业务层处理
 * 
 * @author shan
 * @date 2024-12-05
 */
@Service
public class MgmtBaseSpuServiceImpl implements IMgmtBaseSpuService 
{
    @Autowired
    private MgmtBaseSpuMapper mgmtBaseSpuMapper;

    /**
     * 查询产品管理
     * 
     * @param id 产品管理主键
     * @return 产品管理
     */
    @Override
    public MgmtBaseSpu selectMgmtBaseSpuById(Long id)
    {
        return mgmtBaseSpuMapper.selectMgmtBaseSpuById(id);
    }

    /**
     * 查询产品管理列表
     * 
     * @param mgmtBaseSpu 产品管理
     * @return 产品管理
     */
    @Override
    public List<MgmtBaseSpu> selectMgmtBaseSpuList(MgmtBaseSpu mgmtBaseSpu)
    {
        return mgmtBaseSpuMapper.selectMgmtBaseSpuList(mgmtBaseSpu);
    }

    /**
     * 新增产品管理
     * 
     * @param mgmtBaseSpu 产品管理
     * @return 结果
     */
    @Override
    public int insertMgmtBaseSpu(MgmtBaseSpu mgmtBaseSpu)
    {
        return mgmtBaseSpuMapper.insertMgmtBaseSpu(mgmtBaseSpu);
    }

    /**
     * 修改产品管理
     * 
     * @param mgmtBaseSpu 产品管理
     * @return 结果
     */
    @Override
    public int updateMgmtBaseSpu(MgmtBaseSpu mgmtBaseSpu)
    {
        return mgmtBaseSpuMapper.updateMgmtBaseSpu(mgmtBaseSpu);
    }

    /**
     * 批量删除产品管理
     * 
     * @param ids 需要删除的产品管理主键
     * @return 结果
     */
    @Override
    public int deleteMgmtBaseSpuByIds(Long[] ids)
    {
        return mgmtBaseSpuMapper.deleteMgmtBaseSpuByIds(ids);
    }

    /**
     * 删除产品管理信息
     * 
     * @param id 产品管理主键
     * @return 结果
     */
    @Override
    public int deleteMgmtBaseSpuById(Long id)
    {
        return mgmtBaseSpuMapper.deleteMgmtBaseSpuById(id);
    }
}
